{% extends "park/base.html" %}
{% block css %}
{% endblock %}
{% block content %}
            <script type="text/javascript">
                var primary_menu = "menu_1";
                var sub_menu = "menu_1_2";
            </script>
            <div class="col-md-12">
                <h3 class="company-name">{{ name}}</h3>
                <div class="panel panel-primary">
                    <div class="panel-heading">
                        <div class="panel-title"><h3>一、获得的行政许可情况（附行政许可文件）</h3></div>
                        <div class="panel-options">
                            <a href="#" data-rel="collapse"><i class="entypo-down-open"></i></a>
                        </div>

                        <div class="stay_right">
{#                            <a href="/basic/law/basic_laws_license/" class="btn btn-info">修改</a>#}
                        </div>
                    </div>
                    <div class="panel-body with-table">

                        <form>
                            <table class="table table-bordered table-responsive">
                                <tr>
                                    <th width="60">序号</th>
                                    <th width="25%">许可文件名称</th>
                                    <th>文号/编号</th>
                                    <th>审批/发证机关</th>
                                    <th>批复时间/有效期限</th>
                                </tr>
                            {% if list_1 %}
                                {% for l in list_1 %}
                                <tr>
                                    {%if forloop.counter == 1%}
                                        <td rowspan="{{ one_length }}">1</td>
                                        <td rowspan="{{ one_length }}">环境影响评价文件批复<br>（在文号编号处注明项目名称）</td>
                                    {% endif %}
                                    <td>
                                            {{  l.serial_number }}
                                    </td>
                                    <td>
                                        {{  l.issuing_authority }}
                                    </td>
                                    <td>
                                            {{  l.expiration }}
                                    </td>
                                </tr>
                                {% endfor %}

                            {% else %}
                                <tr>
                                <td rowspan="1">1</td>
                                <td rowspan="1">环境影响评价文件批复<br>（在文号编号处注明项目名称）</td>
                                <td>
                                </td>
                                <td>
                                </td>
                                <td>
                                </td>
                                </tr>
                            {% endif %}

                                {% if list_2 %}
                                {% for l in list_2 %}
                                <tr>
                                    {%if forloop.counter == 1%}
                                    <td rowspan="{{ two_length }}">2</td>
                                    <td rowspan="{{ two_length }}">建设项目竣工环境保护验收审批文件<br>（在文号编号处注明项目名称）</td>
                                  {% endif %}

                                    <td>
                                        {{  l.serial_number }}
                                    </td>
                                    <td>
                                        {{  l.issuing_authority }}
                                    </td>
                                    <td>
                                        {{  l.expiration }}
                                    </td>
                                </tr>
                                    {% endfor %}
                            {% else %}
                                    <tr>
                                    <td rowspan="1">2</td>
                                    <td rowspan="1">建设项目竣工环境保护验收审批文件<br>（在文号编号处注明项目名称）</td>
                                    <td>
                                    </td>
                                    <td>
                                    </td>
                                    <td>
                                    </td>
                                    </tr>
                            {% endif %}
                                {% if list_3 %}
                                {% for l in list_3 %}
                                <tr>
                                    {%if forloop.counter == 1%}
                                    <td rowspan="{{ three_length }}">3</td>
                                    <td rowspan="{{ three_length }}">污染物排放许可证</td>
                                    {% endif %}
                                    <td>
                                        {{  l.serial_number }}
                                    </td>
                                    <td>
                                        {{  l.issuing_authority }}
                                    </td>
                                    <td>
                                        {{  l.expiration }}
                                    </td>
                                </tr>
                                    {% endfor %}
                                {% else %}
                                    <tr>
                                            <td rowspan="1">3</td>
                                            <td rowspan="1">污染物排放许可证</td>
                                        <td>
                                        </td>
                                        <td>
                                        </td>
                                        <td>
                                        </td>
                                    </tr>
                                {% endif %}



                                {% if list_4 %}
                                {% for l in list_4 %}
                                <tr>
                                    {%if forloop.counter == 1%}
                                    <td rowspan="{{ four_length }}">4</td>
                                    <td  rowspan="{{ four_length }}">危险废物经营许可证</td>
                                    {% endif %}

                                        <td>
                                            {{  l.serial_number }}
                                        </td>
                                        <td>
                                            {{  l.issuing_authority }}
                                        </td>
                                        <td>
                                            {{  l.expiration }}
                                        </td>
                                        </tr>
                                    {% endfor %}
                            {% else %}
                                    <tr>
                                        <td rowspan="1">4</td>
                                        <td  rowspan="1">危险废物经营许可证</td>
                                        <td>
                                        </td>
                                        <td>
                                        </td>
                                        <td>
                                        </td>
                                    </tr>
                            {% endif %}
                                {% if list_5 %}
                                {% for l in list_5 %}
                                <tr>
                                    {%if forloop.counter == 1%}
                                    <td rowspan="{{ five_length }}">5</td>
                                    <td  rowspan="{{ five_length }}">危险化学品安全生产许可证</td>
                                    {% endif %}

                                        <td>
                                            {{  l.serial_number }}
                                        </td>
                                        <td>
                                            {{  l.issuing_authority }}
                                        </td>
                                        <td>
                                            {{  l.expiration }}
                                        </td>
                                        </tr>
                                    {% endfor %}
                                {% else %}
                                    <tr>
                                            <td rowspan="1">5</td>
                                            <td  rowspan="1">危险化学品安全生产许可证</td>
                                        <td>
                                        </td>
                                        <td>
                                        </td>
                                        <td>
                                        </td>
                                    </tr>

                                {% endif %}

                                {% if list_6 %}
                                {% for l in list_6 %}
                                <tr>
                                    {%if forloop.counter == 1%}
                                    <td rowspan="{{ six_length }}">6</td>
                                    <td rowspan="{{ six_length }}">危险化学品安全使用许可证</td>
                                    {% endif %}

                                        <td>
                                            {{  l.serial_number }}
                                        </td>
                                        <td>
                                            {{  l.issuing_authority }}
                                        </td>
                                        <td>
                                            {{  l.expiration }}
                                        </td>
                                        </tr>
                                    {% endfor %}

                                {% else %}
                                    <tr>
                                            <td rowspan="1">6</td>
                                            <td rowspan="1">危险化学品安全使用许可证</td>
                                        <td>
                                        </td>
                                        <td>
                                        </td>
                                        <td>
                                        </td>
                                    </tr>
                                {% endif %}
                                {% if list_7 %}
                                {% for l in list_7 %}
                                <tr>
                                    {%if forloop.counter == 1%}
                                    <td rowspan="{{ seven_length }}">7</td>
                                    <td rowspan="{{ seven_length }}">工业产品生产许可证</td>
                                    {% endif %}
                                        <td>
                                            {{  l.serial_number }}
                                        </td>
                                        <td>
                                            {{  l.issuing_authority }}
                                        </td>
                                        <td>
                                            {{  l.expiration }}
                                        </td>
                                        </tr>
                                    {% endfor %}
                                {% else %}
                                    <tr>
                                            <td rowspan="1">7</td>
                                            <td rowspan="1">工业产品生产许可证</td>
                                        <td>
                                        </td>
                                        <td>
                                        </td>
                                        <td>
                                        </td>
                                    </tr>
                                {% endif %}
                                {% for file in files_1 %}
                                <tr >
                                    {%if forloop.counter == 1%}
                                    <td rowspan="{{ file1_length }}">附件</td>
                                    {% endif %}
                                    <td colspan="4">
                                          <a href="/{{file.upload_file}}">  {{ file.file_name }}</a>
                                    </td>
                                </tr>
                                {% endfor%}
                                <tr>
                                    <td>备注</td>
                                    <td colspan="4">{{ remark_1.remark }}</td>
                                </tr>
                            </table>
                        </form>
                    </div>
                </div>
                <div class="panel panel-primary">
                    <div class="panel-heading">
                        <div class="panel-title"><h3>二、污染物达标排放情况（附一年内环境监测报告）</h3></div>
                        <div class="panel-options">
                            <a href="#" data-rel="collapse"><i class="entypo-down-open"></i></a>
                            <!--<a href="#" data-rel="reload"><i class="entypo-arrows-ccw"></i></a>-->
                        </div>

                        <div class="stay_right">
{#                            <a href="/basic/law/basic_laws_pollution/" class="btn btn-info">修改</a>#}
                        </div>
                    </div>
                    <div class="panel-body with-table">
                        <form>
                            <table class="table table-bordered table-responsive">
                                <tr style="border-top:1px solid #e5e5e5;">
                                    <th width="60">项 目</th>
                                    <th width="25%">监测项目名称</th>
                                    <th>执行标准号</th>
                                    <th>执行级别</th>
                                    <th>达标情况</th>
                                </tr>
                                {% if poll_1 %}
                                {% for l in poll_1 %}
                                <tr>
                                    {%if forloop.counter == 1%}
                                    <td rowspan="{{poll1_length}}">废气</td>
                                    {% endif %}
                                    <td>{{ l.name }}</td>
                                    <td>{{ l.code }}</td>
                                    <td>
                                        {%if l.level == '1' %}
                                            高
                                        {% elif l.level == '2'  %}
                                            中
                                        {% else %}
                                            低
                                        {% endif %}
                                    </td>
                                    <td>
                                        {%if l.status == '1' %}
                                            达标
                                        {% elif l.status == '0'  %}
                                            不达标
                                        {% endif %}
                                    </td>
                                </tr>
                                {% endfor %}
                                {% else %}
                                    <tr>
                                        <td>废气</td>
                                        <td></td>
                                        <td></td>
                                        <td></td>
                                        <td></td>
                                    </tr>
                                {% endif %}
                                {% if poll_2 %}
                                    {% for l in poll_2 %}
                                        <tr>
                                            {%if forloop.counter == 1%}
                                                <td rowspan="{{poll2_length}}">废水</td>
                                            {% endif %}
                                            <td>{{ l.name }}</td>
                                            <td>{{ l.code }}</td>
                                            <td>
                                                {%if l.level == '1' %}
                                                    高
                                                {% elif l.level == '2'  %}
                                                    中
                                                {% else %}
                                                    低
                                                {% endif %}
                                            </td>
                                            <td>
                                                {%if l.status == '1' %}
                                                    达标
                                                {% elif l.status == '0'  %}
                                                    不达标
                                                {% endif %}
                                            </td>
                                        </tr>
                                    {% endfor %}
                                {% else %}
                                    <tr>
                                        <td>废水</td>
                                        <td></td>
                                        <td></td>
                                        <td></td>
                                        <td></td>
                                    </tr>
                                {% endif %}
                                {% if poll_3 %}
                                    {% for l in poll_3 %}
                                        <tr>
                                            {%if forloop.counter == 1%}
                                                <td rowspan="{{poll3_length}}">噪声</td>
                                            {% endif %}
                                            <td>{{ l.name }}</td>
                                            <td>{{ l.code }}</td>
                                            <td>
                                                {%if l.level == '1' %}
                                                    高
                                                {% elif l.level == '2'  %}
                                                    中
                                                {% else %}
                                                    低
                                                {% endif %}
                                            </td>
                                            <td>
                                                {%if l.status == '1' %}
                                                    达标
                                                {% elif l.status == '0'  %}
                                                    不达标
                                                {% endif %}
                                            </td>
                                        </tr>
                                    {% endfor %}
                                {% else %}
                                    <tr>
                                        <td>噪声</td>
                                        <td></td>
                                        <td></td>
                                        <td></td>
                                        <td></td>
                                    </tr>
                                {% endif %}
                                {% for file in files_2 %}
                                    <tr >
                                        {%if forloop.counter == 1%}
                                            <td rowspan="{{ file2_length }}">附件</td>
                                        {% endif %}
                                        <td colspan="4">
                                            <a href="/{{file.upload_file}}">  {{ file.file_name }}</a>
                                        </td>
                                    </tr>
                                {% endfor%}
                                <tr>
                                    <td>备注</td>
                                    <td colspan="4">{{ remark_2.remark }}</td>
                                </tr>
                                </table>
                        </form>
                    </div>
                </div>
                <div class="panel panel-primary">
                    <div class="panel-heading">
                        <div class="panel-title"><h3>三、清洁生产审核情况（附相关证明文件）</h3></div>
                        <div class="panel-options">
                            <a href="#" data-rel="collapse"><i class="entypo-down-open"></i></a>
                            <!--<a href="#" data-rel="reload"><i class="entypo-arrows-ccw"></i></a>-->
                        </div>

                        <div class="stay_right">
{#                            <a href="/basic/law/basic_laws_clean/" class="btn btn-info">修改</a>#}
                        </div>
                    </div>
                    <div class="panel-body with-table">

                        <form>
                            <table class="table table-bordered table-responsive">
                                <tr style="border-top:1px solid #e5e5e5;">
                                    <th width="25%">是否属于强制清洁生产审核单位</th>
                                    <td width="25%">
                                        {% if clean.enforcement == '0' %}
                                                    否
                                        {% elif clean.enforcement == '1' %}
                                            是
                                        {% endif %}
                                    </td>
                                    <th width="25%">清洁生产审核开展情况</th>
                                    <td width="25%">
                                        {% if clean.launch == '0' %}
                                            未开展
                                        {% elif clean.launch == '1' %}
                                            开展
                                        {% endif %}
                                    </td>
                                </tr>
                                <tr>
                                    <th>清洁生产审核评估情况</th>
                                    <td>
                                        {% if clean.evaluation == '0' %}
                                            未评估
                                        {% elif clean.evaluation == '1' %}
                                            评估
                                        {% endif %}
                                    </td>
                                    <th>清洁生产审核验收情况</th>
                                    <td>
                                        {% if clean.acceptance == '0' %}
                                            未验收
                                        {% elif clean.acceptance == '1' %}
                                            已验收
                                        {% endif %}
                                    </td>
                                </tr>
                                <tr>
                                    <th>最近一次清洁生产审核评估或验收时间</th>
                                    <td>{{ clean.most_recently }}</td>
                                    <th>清洁生产审核评估或验收部门</th>
                                    <td>{{ clean.department }}</td>
                                </tr>
                                {% for file in files_3 %}
                                    <tr >
                                        {%if forloop.counter == 1%}
                                            <th rowspan="{{ file3_length }}">附件</th>
                                        {% endif %}
                                        <td colspan=4>
                                            <a href="/{{file.upload_file}}">  {{ file.file_name }}</a>
                                        </td>
                                    </tr>
                                {% endfor%}
                                <tr>
                                    <th>备注</th>
                                    <td colspan=4>{{ clean.remark }}</td>
                                </tr>
                            </table>
                        </form>
                    </div>
                </div>
                <div class="panel panel-primary">
                    <div class="panel-heading">
                        <div class="panel-title"><h3>四、应急预案及突发环境事件</h3></div>
                        <div class="panel-options">
                            <a href="#" data-rel="collapse"><i class="entypo-down-open"></i></a>
                            <!--<a href="#" data-rel="reload"><i class="entypo-arrows-ccw"></i></a>-->
                        </div>

                        <div class="stay_right">
{#                            <a href="/basic/law/basic_laws_emergency/" class="btn btn-info">修改</a>#}
                        </div>
                    </div>
                    <div class="panel-body with-table">
                        <form>
                            <table class="table table-bordered table-responsive">
                                <tr style="border-top:1px solid #e5e5e5;">
                                    <th width="25%">是否编制应急预案</th>
                                    {%if emer.file_ids%}
                                    <td width="25%">是</td>
                                    {%else%}
                                    <td width="25%">否</td>
                                    {% endif %}
                                    <th width="25%">编制时间</th>
                                    <td width="25%">{{emer.preparation_time}}</td>
                                </tr>
                                <tr>
                                    <th>应急预案是否备案</th>
                                    {%if emer.is_record%}
                                    <td>是</td>
                                    {%else%}
                                    <td>否</td>
                                    {% endif %}
                                    <th>备案时间及单位</th>
                                    <td>{{emer.filing_time}}</td>
                                </tr>
                                <tr>
                                    <th>近10年发生突发环境事件情况</th>
                                    <td colspan="4">
                        			{%if emer.drill%}
                        				有&nbsp;&nbsp;&nbsp;&nbsp;共{{emer.drill_times}}次</td>
                        			{%else%}
                       				 	无
                        			{% endif %}
                                        
                                </tr>
                            </table>
                        </form>
                    </div>
                </div>
            </div>

{% endblock %}

{% block js %}
{% endblock %}